# -*- coding: utf-8 -*-
"""
Version: 0.1
Author: CarpeDiem
Date: 2022/3/30
Description: 模拟火车订票系统
"""
station = [
    "车次", "出发站-到达站", "出发时间", "到达时间", "历时", "T40", "长春-北京", "00:12", "12:20",
    "12:08", "T298", "长春-北京", "00:06", "10:50", "10:44", "Z158", "长春-北京",
    "12:48", "21:06", "08:18", "Z62", "长春-北京", "21:58", "06:08", "8:20"
]
for index, item in enumerate(station):
    if (index + 1) % 5 == 0:
        print(item + "\n")
    else:
        print(item + "\t\t", end='')
a = input("请输入要购买的车次：")
b = input("请输入乘车人（用逗号隔开）：")
m = len(station)
for i in range(m):
    if a == station[i]:
        print("您已购" + str(a) + "次列车 " + station[i + 1] + " " + station[i + 2] +
              "开，请" + str(b) + "尽快换取纸质车票。【铁路客服】")
